1. Field of the Invention
The present invention generally relates to logically partitioned computer systems and more particularly to processing virtual interrupts targeting a logical partition.
2. Description of the Related Art
In a computing environment, parallel processing generally refers to performing multiple computing tasks in parallel. Traditionally, parallel processing required multiple computer systems, with the resources of each computer system dedicated to a specific task, or allocated to perform a portion of a common task. However, recent advances in computer hardware and software technologies have resulted in single computer systems capable of highly complex parallel processing, by logically partitioning the system resources to different tasks. In a logically partitioned computer system, available system resources are allocated among multiple logical partitions, each designed to appear to operate independently of the other. Management of the allocation of resources among logical partitions is typically accomplished via a layer of software components, commonly referred to as a partition manager.
An objective of the partition manager is to allow each logical partition to independently run software (e.g., operating systems and operating system-specific applications), typically developed to run on a dedicated computer system, with little or no modification. For example, one logical partition may be running a first operating system, such as IBM's OS/400, a second logical partition may be running a second operating system, such as IBM's AIX, while a third logical partition may be running a third operating system, such as Linux. By providing the ability to run multiple operating systems on the same computer system, a logically partitioned system may provide a user with a greater degree of freedom in choosing application programs best suited to the user's needs with little or no regard to the operating system for which an application program was written.
The partition manager typically accomplishes the objective of allowing each of the logical partitions to independently run software by presenting each logical partition with a set of virtual resources (software components) that operate, from the perspective of the logical partition, in an identical manner to corresponding hardware components. In other words, the partition manager may allow each logical partition to, in affect, operate as an independent virtual computer system (or virtual machine) with its own set of virtual resources.
The virtual resources presented to each logical partition may include one or more virtual processors. The virtual processors for each partition may share the processing resources of one or more physical processors assigned to the partition. To provide support for other types of virtual devices and to allow multiple operating systems to share a processor on a partitioned system, the virtual processor may be able to process virtual interrupts. In other words, a virtual interrupt may be generated by a virtual device, just as an actual hardware device may generate an interrupt on a physical processor, or may be generated as a result of an actual hardware interrupt re-routed from a different partition than the one running a virtual processor receiving the virtual interrupt. Concepts of creating virtual interrupts are described in detail in the commonly owned patent application, Ser. No. 10/403,158, filed Mar. 31, 2003, entitled “Apparatus and Method for Virtualizing Interrupts in a Logically Partitioned Computer System,” which is herein incorporated by reference.
Computer systems with multiple physical processors, such as logically partitioned computer systems, may utilize an interrupt management mechanism (commonly referred to as a global interrupt queue) that essentially designates which of the physical processors in the system may be the target of an interrupt by an I/O device. Upon receiving an interrupt, global interrupt queue hardware (and/or software) may choose one of the associated physical processors for presentation of the interrupt, thereby spreading the overhead of interrupt processing among multiple processors. In some instances, a global interrupt queue may be designed to present an interrupt to a selected one of the physical processors that is in an executing state more favorable to processing the interrupt than others. For example, other physical processors may be busy processing other partition tasks or may already be processinganother interrupt (e.g., with a higher priority level).
As virtual processors are designed to behave in a similar manner to physical processors, a set of virtual processors assigned to a logical partition may also have executing states that are more favorable to processing virtual interrupts than others. To ensure an interrupt targeting the logical partition is handled as soon as possible, it would be desirable that the interrupt be presented to a virtual processor in the most favorable executing state. However, there is currently no mechanism (e.g., with functionality analogous to that of a global interrupt queue) for receiving a virtual interrupt and routing it to a virtual processor in an operating state most favorable for processing it.
Accordingly, there is a need for an improved method and system for processing virtual interrupts, for example, by implementing a virtual global interrupt queue configured to route virtual interrupts to virtual processors determined to be in operating states favorable for processing the virtual interrupts.